#ifndef CLICKEDLABEL_H
#define CLICKEDLABEL_H

#include<QLabel>
#include"global.h"

class ClickedLabel: public QLabel
{
    Q_OBJECT
public:
    ClickedLabel(QWidget *parent);
    void mousePressEvent(QMouseEvent *ev) Q_DECL_OVERRIDE;
    virtual void enterEvent(QEvent *event);
    virtual void leaveEvent(QEvent *event);
    void SetState(QString normal = "",
                  QString normal_hover = "",
                  QString normal_press = "",

                  QString selected = "",
                  QString selected_hover = "",
                  QString selected_press = "");
    ClickLbState GetCurState();
signals:
    void clicked(void);
private:
    QString _normal;
    QString _normal_hover;
    QString _normal_press;

    QString _selected;
    QString _selected_hover;
    QString _selected_press;

    ClickLbState _cur_state;
};

#endif // CLICKEDLABEL_H
